﻿using System;
using System.Collections.Generic;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using KYO.DAL;
using ObjectPersistence;
using BusinessLayerHelper;

public partial class Admin_Controls_Mod_Tab_Tab : ViewControlBase<Tab>
{
    TabAssembler tabService = new TabAssembler();
    protected void Page_Load(object sender, EventArgs e)
    {
       
    }
    protected override void OnInit(EventArgs e)
    {
        LoadTabData();
        base.OnInit(e);
    }
    void LoadTabData()
    {
        PersistentList<Tab> tabs = tabService.ReadCollectionAll();

        ddl_ParentId.DataSource = tabs;
        ddl_ParentId.DataTextField = "Name";
        ddl_ParentId.DataValueField = "TabId";
        ddl_ParentId.DataBind();
        ddl_ParentId.Items.Insert(0, new ListItem("--root--", "0"));

    }



}